package com.zhl.study.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @description TODO
 * @Author: z156940l@outlook.com
 * @className DealService
 * @Date: 2023/4/28 17:52
 */
@Service
public class DealService {

    static final ThreadLocal<String> threadLocal = new ThreadLocal();

    @Autowired
    private AService aService;

    public void dealTransfer() {
        String address = "nanjing";
        threadLocal.set(address);
        A();
    }

    private void A() {
        B();
    }

    private void B() {
        aService.C();
    }
}

